Name Tag

Introduction

Tell everyone who you are. Show you name on the LEDs.

Name scrolling on the LEDs

Step 1

On the screen, ||basic:show a string|| saying "My name is: ".

basic.showString("My name is: ")

Step 2

Let everyone know who you are and ||basic:show a string|| with your name.

basic.showString("My name is: ")
basic.showString("Sarah!")

Step 3

Tell everyone what your age is. Add a ||basic:show string|| for "My age is " and then ||basic:show a number|| for your age.

basic.showString("My name is: ")
basic.showString("Sarah!")
basic.showString("My age is: ")
basic.showNumber(9)

Step 4

Look at the simulator and make sure it shows your name and age on the screen.

Step 5

Place more ||basic:show strings|| to create a longer message.

basic.showString("My name is: ")
basic.showString("Sarah!")
basic.showString("My age is: ")
basic.showNumber(9)
basic.showString("Favorite color: ")
basic.showString("Blue")

Step 6

If you have a micro:bit connected, click |Download| and transfer your code to the micro:bit!